<script setup>
import { defineEmits, defineProps,defineExpose, toRefs } from 'vue'
import { Message, Modal } from "@garco-design/web-vue";
const props = defineProps({
  // 标题
  title: {
    required: true,
    default: '删除'
  },
   // 内容
   content: {
    required: true,
    default: '是否确定要删除此条数据'
  }
})
const {title,content } = toRefs(props)
// 处理方法
const handleOpenDeleteModal = () => {
  Modal.warning({
    title: `${title.value}`,
    // titleAlign: "",
    content: `${content.value}`,
    hideCancel: false,
    onBeforeOk: async () => {
      // await updataClusterDbAccounts(props.row.clusterType, props.row.uuid, {
      //   operator: "disable",
      // });
      Message.success("操作成功");
      // emits("fetchData");
    },
  });
}
defineExpose({handleOpenDeleteModal})
</script>

<style lang='scss' scoped>
.garco-tag-size-medium {
  padding: 7px 18px;
  height: 26px;
  line-height: 26px;
}
</style>
